<%@ Page Language="VB" MasterPageFile="~/Admin/Admin.master" AutoEventWireup="false" CodeFile="HomePageDashboard.aspx.vb" Inherits="Admin_HomePageDashboard" title="Admin - Home Page Dashboard Settings" %>
<%@ Register Assembly="InputControls" Namespace="InputControls" TagPrefix="cc2" %>
<%@ Register Src="SubNavControls/RolePermissionsSubNavControl.ascx" TagName="RolePermissionsSubNavControl"
    TagPrefix="uc1" %>
    
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder2" Runat="Server">
<script language="javascript" type="text/javascript">
function showPageNotes()
{
alert("This page is used to configure which dashboard controls are shown on the home page.\n\n " +
      "In general, it should be used to change the title shown above a control, to hide a control that was configured by default, or to change the order of control display.\n\n" +
      "If you are assigning new controls to current user types (which this page allows you to do), please use caution.  There are limits to the use of the controls.\n\n" +
      "The first is that Alerts and Notifications do not have any meaning for any of the guest users, or the sys admin user.  Each of these are " +
      "set according to the current user's list of participants.  Since guest users do not have associations with participants, displaying these controls on the home page would have no meaning.\n\n" + 
      "In addition, note that controls like FMSA Support Brokers, Support Broker Files, FMSA Participant List, and SBA Support Broker List, really only apply to specific roles.\n\n" +
      "Please keep these in mind when updating this page.");
}
</script>
    <uc1:RolePermissionsSubNavControl ID="RolePermissionsSubNavControl1" runat="server" />
    <table cellpadding="0" cellspacing="0" border="0" width="910px">
       <tr><td style="width:20px;" valign="top"></td><td align="left" style="width:440px;"><h1><a id="pagecontent">Admin - Set Home Page Dashboards by Role</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a id="A1" class="adminHeaderStyle" style="font-weight:normal; color:Blue;" href="javascript:showPageNotes();">Notes</a></h1></td><td style="width:450px;" align="right" valign="bottom"><asp:label ID="RoleLabel" runat="server" AssociatedControlID="RolesDropDownList" CssClass="adminSelectLabel" Text="Select Role:"></asp:label>
            <asp:DropDownList ID="RolesDropDownList" runat="server" CssClass="adminSelectForm" DataSourceID="RolesObjectDataSource" DataValueField="RoleId"
                DataTextField="RoleDisplayName" AutoPostBack="False">
            </asp:DropDownList>
              <asp:Button ID="SubmitRoleButton" runat="server" Text="Go" /></td>
       </tr>
       
       <tr><td colspan="3" align="center">
       <asp:GridView ID="DashboardGridView" runat="server" CssClass="gridOffsetSmall" Width="700px" AutoGenerateColumns="False" Caption="Set the Grids to display on the dashboard section of each user type's home page." CaptionAlign="Top"
             DataKeyNames="DashboardId, RoleId" CellPadding="5" BorderColor="#21334B" BorderStyle="Solid" 
            GridLines="Vertical" AllowSorting="true">
        <HeaderStyle  CssClass="adminHeaderStyle" BackColor="#C3CAD4" BorderColor="#21334B" VerticalAlign="Top" />
        <RowStyle CssClass="adminColumnStyle" />
        <Columns>
            <asp:BoundField DataField="DisplayOrder" HeaderText="DisplayOrder" />
            <asp:TemplateField HeaderText="Dashboard Item" >
                <ItemTemplate><asp:DropDownList ID="DashboardItemDropDownList" DataSourceID="DashboardItemsObjectDataSource" DataTextField="Description" DataValueField="ControlName" runat="server"></asp:DropDownList>
                </ItemTemplate>
            </asp:TemplateField>
            
            <asp:TemplateField HeaderText="Section Title" ItemStyle-HorizontalAlign="center">
                <ItemTemplate>
                    <asp:TextBox ID="TitleTextBox" runat="server" Text='<%#Eval("Title")%>' />
                </ItemTemplate>
            </asp:TemplateField>
                       </Columns>
        <AlternatingRowStyle BackColor="#E8ECF4" />
        </asp:GridView></td></tr>
        <tr height="3"><td colspan="3"></td></tr>
        <tr><td colspan="3" style="text-align:center;"><asp:Button ID="SaveButton" runat="server" Text="Save" />
      <asp:Button ID="CancelButton" runat="server" Text="Cancel" /></td></tr>
    </table>
           <asp:ObjectDataSource ID="RolesObjectDataSource" runat="server" SelectMethod="ListActive" TypeName="Cdm.DataCore.UserSecurity.Role">
            </asp:ObjectDataSource>
            <asp:ObjectDataSource ID="DashboardItemsObjectDataSource" runat="server" SelectMethod="ListAll" TypeName="Cdm.DataCore.LookupTables.LuDashboardItem"></asp:ObjectDataSource>
</asp:Content>
